<?php if (!defined('THINK_PATH')) exit();?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
<head>
	<meta http-equiv="Content-Type" content="text/html;charset=UTF-8" />
	<title></title>
	<link rel="stylesheet" type="text/css" href="__PUBLIC__/Admin/css/common.css">
</head>
<body>
	<div class="status"><span>货品修改</span><a class='back' href="<?php echo U('item',array('id'=>$_GET['id'],'gid'=>$_GET['gid']));?>"><strong>返回货品列表<b></b></strong></a></div>
	<form method='post' action="<?php echo U('runUpdateItem');?>">
		<table class="table">
			<tr>
				<th>ID</th>
				<?php if(is_array($typeName)): foreach($typeName as $key=>$v): ?><td><?php echo ($v["name"]); ?></td><?php endforeach; endif; ?>
				<td>库存</td>
				<td>货号</td>
				<td>操作</td>
			</tr>
			<tr>
				<td><?php echo ($data["id"]); ?></td>
				<?php if(is_array($goodsAttr)): foreach($goodsAttr as $key=>$v): ?><td>
					<select  class='select' name='attr[]'>
						<option>请选择</option>
						<?php if(is_array($v)): foreach($v as $key=>$value): ?><option	value='<?php echo ($value["id"]); ?>' <?php if(in_array($value['id'],$attr_id)): ?>selected='selected'<?php endif; ?> ><?php echo ($value["value"]); ?></option><?php endforeach; endif; ?>
					</select>
					</td><?php endforeach; endif; ?>
				<td><input type='text' class='text' name='inventory' value='<?php echo ($data["inventory"]); ?>'/></td>
				<td><input type='text' class='text' name='number' value='<?php echo ($data["number"]); ?>'/></td>
				<td>
					<input type='hidden' name='id' value='<?php echo ($data["id"]); ?>'/>
					<input type='hidden' name='gid' value="<?php echo ($_GET['gid']); ?>"/>
					<input type='submit' class='add_btn' value='保存修改'/>
				</td>
			</tr>
		</table>
	</form>
</body>
</html>